﻿<!DOCTYPE html>

<html>

<head>

    <meta charset="utf-8">

    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>

    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">

    <meta name="format-detection" content="telephone=no">

    <meta name="apple-mobile-web-app-capable" content="yes">

    <meta name="apple-mobile-web-app-status-bar-style" content="black">

    <title>外来人口积分查询</title>

    <link type="text/css" href="/szgawx/static/plugins/css/common.css" rel="stylesheet"/>
    <script src="/szgawx/static/plugins/js/FormValid.js"></script>

    <style type="text/css">

        .main {

        font-size: 1.6em;

        margin: 8px;

        }

        .main .form {

        height: 50px;

        line-height: 50px;

        border: 1px solid #dddddd;

        width: 100%;

        border-radius: 3px;

        }

        .main .form .label {

        height: 50px;

        line-height: 50px;

        color: #157dfb;

        text-indent: 0.8em;

        float: left;

        width: 143px;
        
		margin-left:-10px;
        }

        .main .form .element {

        height: 50px;

        line-height: 50px;

        margin-left: 138px;

        display: block;

        }

        .main .form .element input {

        color: #666;

        font-family: "微软雅黑", serif;

        text-indent: 0.3em;

        border: 0;

        width: 98%;

        font-size: 1.0em;

        overflow: hidden;

        white-space: nowrap;

        text-overflow: ellipsis;

        }



        .main .btn:active {

        background-color: #3300ff;

        cursor: hand;

        }

        #result {

        min-height: 6em;

        margin: 0px 10px;

        line-height: 2;

        height: 2em;

        color: #837D7D;

        }

		.tab_title {

        height: 33px;

        border: 1px solid #157dfb;

        border-radius: 6px;

        background-color: #157dfb;

    }



    .tab_title .tab_item {

        width: 50%;

        display: inline-block;

        float: left;

        text-align: center;

        height: 33px;

        line-height: 33px;

        color: #706C6C;

        font-size: 1.6em;

        cursor: hand;

        background-color: #fff;

    }



    .tab_title .checked {

        background-color: transparent;

        color: #fff;

    }



    .tab_title .tab_left {

        border-top-left-radius: 5px;

        border-bottom-left-radius: 5px;

    }



    .tab_title .tab_right {

        border-top-right-radius: 5px;

        border-bottom-right-radius: 5px;

    }

	.title-bar {

        border: none;

		top: 0;

		height: 2.6em;

		line-height: 2.6em;

		text-indent: 0.4em;

		width: 100%;

		font-size: 1.8em;

		font-weight: 500;

		color: #eaeaea;

		background-color: #000000;

		display: -webkit-box;

		z-index: 999;

    }



    .title-bar .title {

        background-color: #17b4eb;

        -webkit-box-flex: 1;

        text-align: center;

        display: block;

    }



    .title-bar .btn-back {

        background-color: #17b4eb;

        border-top-left-radius: 0.7em;

        display: block;

        width: 3.0em;

        border-right: 1px solid rgba(197, 238, 220, 0.67);

    }



    .title-bar .btn-oper {

        border-top-right-radius: 0.7em;

        background-color: #17b4eb;

        display: block;

        width: 3.0em;

        text-align: center;

        width: -webkit-fit-content;

        min-width: 3.0em;

    }
    
     a {
 	 	text-decoration: none;
	  }

    </style>

</head>

<body>

<div class="main">
<form id="a">
    <div class="form">

        <span class="label">身份证号码：</span>

        <span class="element"><input id="txt_idcard" name="txt_idcard" value="" class="no-border" type="text" valid='isEnglishOrNum' errmsg='请输入身份证号码' placeholder="请输入身份证号码"/></span>

    </div>
    
     <div class="form">

        <span class="label">社保保障卡卡号：</span>

        <span class="element"><input id="txt_sbk" name="txt_sbk" value="" class="no-border" type="text" valid='isEnglishOrNum' errmsg='请输入社保保障卡卡号' placeholder="请输入社保保障卡卡号"/></span>

    </div>

    <div><a href="javascript:;" id="btn_query" class="btn simple no-border">查 询</a></div>
</form>
    <div id="result" style="display: none;">

        <div>

            <span>申请人姓名：</span>

            <span id="txt_1"></span>

        </div>

        <div>

            <span>身份证号码：</span>

            <span id="txt_2"></span>

        </div>

        <div>

            <span>基础分：</span>

            <span id="txt_3"></span>

        </div>

        <div>

            <span>附加分：</span>

            <span id="txt_4"></span>

        </div>

        <div>

            <span>扣减分：</span>

            <span id="txt_5"></span>

        </div>

        <div>

            <span>总分：</span>

            <span id="txt_6"></span>

        </div>

        <div>

            <span>上半年入户排名名次：</span>

            <span id="txt_7"></span>

        </div>

    </div>

</div>

<script type="text/javascript" src="/szgawx/static/plugins/js/jquery-2.1.1.min.js"></script>

<script type="text/javascript" src="/szgawx/static/plugins/js/common.js"></script>

<script type="text/javascript">

var _preFix = getServerPreFix();
var theRequest = GetRequest();
document.addEventListener("deviceready", function(){

			navigator.splashscreen.hide();  

		}, false);

function goBack(){

		navigator.intent.goback(0);

	}

    $(function () {
        $("#btn_query").click(function (event) {
        	 var txt_sbk = $("#txt_sbk").val().trim();
             var idcard = $("#txt_idcard").val().trim();
             if (txt_sbk == null || txt_sbk == "") {
                 toast("请输入社保卡");
                 return;
             }
             if (idcard == null || idcard == "") {
                 toast("请输入身份证号码");
                 return;
             }

            $.ajax({

                url: _preFix+"/szgawx/api/query/queryPointsScore?source="+theRequest['source']+"&openId="+theRequest['openId'],

                type: "post",
                
                dataType:"json",
                
                data: {"idcard": idcard, "sbk": txt_sbk},

                timeout: 6000,

                beforeSend: function () {

                    loading();

                },

                success: function (data) {
                    if (data && data.succ&&data.data) {
                    	
                        $("#txt_1").html(data.data.name);
                        $("#txt_2").html(data.data.idcard);
                        $("#txt_3").html(data.data.baseScore);
                        $("#txt_4").html(data.data.additionalScore);
                        $("#txt_5").html(data.data.subScore);
                        $("#txt_6").html(data.data.scores);
                        $("#txt_7").html(data.data.rank);
                        
                        $("#result").show();
                        $("#tip").hide();
                        finish();

                    } else {

                        finish("没有查询到相应的数据");

                    }

                },
 
                error: function (e) {
                 for(var k in e)
                 {
                 	//alert(k+"    "+e[k])
                 }
                    finish("查询失败");
                   // window.location.href = _preFix + "/szgawx/oauth/oauth?state="+_preFix+"/szgawx/api/query/11";
                }

            });

            event.stopPropagation();

            return false;

        });

    });
    function validate()
	{
		  
        if(validator(E("a"))){
        	return true;
        }
        else
       	{
       		return false;
       	}
	}

</script>

<div id="tip" style="width:94%; float:left; margin-left:3%; line-height:28px; font-family:'微软雅黑'; font-size:14px; color:#ff0000; position:absolute; bottom:10px;">
提示说明：
<div>1）此分值非最终分值；按照规定后期相关职能部门将进一步开展扣减分审核流程，分值以最终公示时为准。</div>

<div>2）个别参加积分申请时未提供社会保障卡卡号的申请人，请直接输入身份证号进行查询。</div>

 <div >   提醒： 社会保障卡卡号的编号为9位长度，首位字母+8位数字的格式。</div>
</div>

</body>

</html>

